var t = getApp();

Page({
    data: {
        id: "",
        serviceData: {}
    },
    onLoad: function(t) {
        this.setData({
            id: t.id
        }), this.getData();
    },
    onReady: function() {},
    onShow: function() {},
    onHide: function() {},
    onUnload: function() {},
    onShareAppMessage: function() {},
    toChat: function() {
        wx.navigateTo({
            url: this.data.serviceData.mini_url
        });
    },
    toHome: function() {
        wx.reLaunch({
            url: "/packageG/index/index"
        });
    },
    getData: function() {
        var a = this, n = t.getNetAddresss("plugin.yun-chat.frontend.h5.employee.get-detail");
        t._getNetWork({
            url: n,
            data: {
                id: this.data.id
            },
            success: function(n) {
                var e = n.data;
                1 == e.result ? a.setData({
                    serviceData: e.data
                }) : t.tips(e.msg);
            },
            fail: function(t) {
                console.log(t);
            }
        });
    }
});